﻿<%@ Page Language="C#" MasterPageFile="~/Views/Shared/Free.Master" Inherits="System.Web.Mvc.ViewPage" %>

<%@ Import Namespace="Pp.Globalization" %>
<%@ Import Namespace="Pp.UI.Models" %>
<%@ Import Namespace="Pp.Dto" %>
<%@ Import Namespace="Ilgera.TMS.UI.Web.Helpers" %>
<%@ Import Namespace="Pp.Core.Extentions" %>
<asp:Content ID="registerContent" ContentPlaceHolderID="MainContent" runat="server">
    <div id="content-panel">
        <h2>
            <%=Res.Label_New_Account  %></h2>
        <p>
            <%=Res.Message_Account %>
        </p>
        <p>
            <%=Res.Format_Max_Lenght_Password.FormatWith(ViewData["PasswordLength"]) %>
            <%=Html.ValidationSummary() %>
        </p>
        <div id="register">
            <% using (Html.BeginForm("Register","Account"))
               {%>
            <%=Html.TextBox<RegisterModel>(Res.Label_Username,d=>d.UserName) %>
            <%=Html.TextBox<RegisterModel>(Res.Label_MailAdress, d => d.Email)%>
            <%=Html.Password<RegisterModel>(Res.Label_Password, d => d.Password)%>
            <%=Html.Password<RegisterModel>(Res.Label_RePassword, d => d.ConfirmPassword)%>
            <%=Html.Submit(Res.Label_Register , false)  %>
            <%}%>
        </div>
        <div style="clear: both;">
        </div>
    </div>
    <script language="javascript">
        $(document).ready(function () {
            $("input[name='UserName']").change(function () {
                ControlUserName($(this));
            });
            $("#BirthDay").datepicker();
            $("#BirthDay").datepicker("option", "changeYear", true);
            $("#BirthDay").datepicker("option", "changeMonth", true);
        });
       
    </script>
    <%--  <script>$('#{0}').change(function () { if ($(this).attr('checked')) { $(this).parent().find('div.checkInfo{0}').text('true'); } else { $(this).parent().find('div.checkInfo{0}').text('faşlse'); } });</script>--%>
</asp:Content>
